<template>
	<view class="alert-pop-wrap">
		<view class="alert-pop-mask" @tap.stop="maskClk"></view>
		<view class="alert-pop">
			<view class="pop-title">{{title}}</view>
			<view class="pop-content">{{content}}</view>
			<view class="pop-btns">
				<view class="pop-btn" @tap.stop="btnClk">{{btnText}}</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		name: "alertPop",
		props:{
			title:{
				type: String,
				default: '提示'
			},
			content:{
				type: String,
				default: ''
			},
			btnText:{
				type: String,
				default: '确定'
			}
		},
		data() {
			return {

			};
		},
		methods: {
			maskClk() {
				this.$emit('maskClk')
			},
			btnClk() {
				this.$emit('btnClk')
			}
		}
	}
</script>

<style lang="less">
	.alert-pop-mask {
		position: fixed;
		top: 0;
		left: 0;
		width: 100%;
		height: 100%;
		background-color: rgba(0, 0, 0, 0.3);
		z-index: 999;
	}

	.alert-pop {
		position: fixed;
		top: 30%;
		left: 75rpx;
		width: 600rpx;
		background: #FFFFFF;
		border-radius: 10rpx;
		box-sizing: border-box;
		padding: 36rpx 72rpx 44rpx 72rpx;
		z-index: 1000;

		.pop-title {
			font-weight: 600;
			color: #333333;
			line-height: 50rpx;
			font-size: 36rpx;
			text-align: center;
		}

		.pop-content {
			margin-top: 30rpx;
			font-size: 30rpx;
			font-weight: 400;
			color: #323746;
			line-height: 48rpx;
		}

		.pop-btns {
			margin-top: 38rpx;
			display: flex;
			justify-content: center;

			.pop-btn {
				background-color: #3399FF;
				border-radius: 6rpx;
				font-size: 32rpx;
				font-weight: 500;
				color: #FFFFFF;
				line-height: 40rpx;
				padding: 18rpx 36rpx;
				min-width: 232rpx;
				box-sizing: border-box;
				text-align: center;

			}
		}
	}
</style>
